﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using Stamp_For_Africa_Version_2.Models;
using Stamp_For_Africa_Version_2.Repositories;

namespace Stamp_For_Africa_Version_2.ViewModels
{
	public class StampFormViewModel
	{
		public Stamp			Stamp { get; private set; }
		public SelectList Countries { get; private set; }

		private CountryRepository _countryRepository = new CountryRepository();

		public StampFormViewModel()
		{
			Stamp = new Stamp();
			Country country = _countryRepository.GetCountry(new Guid("00000000-0000-0000-0000-000000000000"));
			Countries = new SelectList(_countryRepository.FindAllCountries(), Stamp.Country = country);
		}

		public StampFormViewModel(Stamp stamp)
		{
			Stamp = stamp;
			Countries = new SelectList(_countryRepository.FindAllCountries(), stamp.Country);
		}

		
	}
}